﻿using AnyLink.Domain.Enums;
using Newtonsoft.Json;
using SqlSugar;

namespace AnyLink.Domain.Entities.System
{
    /// <summary>
    /// 字典类型表
    /// </summary>
    [SugarTable("sys_dict_type", TableDescription = "字典类型表", IsDisabledUpdateAll = true)]
    public class SysDictType : BaseAuditedEntity<long>
    {
        /// <summary>
        /// 字典主键
        /// </summary>
        [SugarColumn(ColumnName = "dict_id", IsPrimaryKey = true, ColumnDescription = "字典主键")]
        [JsonProperty(propertyName: "dictId")]
        public override long Id { get; set; }

        /// <summary>
        /// 字典名称
        /// </summary>
        [SugarColumn(ColumnName = "dict_name", ColumnDataType = "VARCHAR(100)", ColumnDescription = "字典名称", IsNullable = true)]
        public string DictName { get; set; }

        /// <summary>
        /// 字典类型
        /// </summary>
        [SugarColumn(ColumnName = "dict_type", ColumnDataType = "VARCHAR(100)", ColumnDescription = "字典类型", IsNullable = true)]
        public string DictType { get; set; }

        /// <summary>
        /// 状态（0正常 1停用）
        /// </summary>
        [SugarColumn(ColumnName = "status", ColumnDescription = "状态（0正常 1停用）", IsNullable = true)]
        public StatusEnum Status { get; set; }        

        /// <summary>
        /// 备注
        /// </summary>
        [SugarColumn(ColumnName = "remark", ColumnDataType = "VARCHAR(500)", ColumnDescription = "备注", IsNullable = true)]
        public string Remark { get; set; }
    }
}